#include "define.h"


/*
 * @brief: dynamic create
 */
RuntimeClass * RuntimeClass::m_pFirstClass = 0;
core::FaceObject * RuntimeClass::CreateObject( const char * id )
{
    core::FaceObject * retObj = 0;
    for( RuntimeClass * pNext = RuntimeClass::m_pFirstClass; pNext != 0;pNext = pNext->m_pNextClass )
    {
        if( pNext->m_pfnCreateObject == 0 ) 
        {
            continue;
        }

        retObj = pNext->m_pfnCreateObject( id );
        if( retObj ) 
            break;
    }

    return retObj;
}